﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Domain.审计字段;

namespace PersonnelSystemManagement.系统管理
{
    /// <summary>
    /// 公司信息表
    /// </summary>
    public class CompanyInfo : AuditableEntityBase
    {
        /// <summary>
        /// 主键 ID
        /// </summary>
        [Key]
        public int id { get; set; }

        /// <summary>
        /// 公司名称
        /// </summary>
        [StringLength(100, ErrorMessage = "公司名称长度不能超过 100 个字符")]
        public string? CompanyName { get; set; }

        /// <summary>
        /// 公司邮箱
        /// </summary>
        [StringLength(100, ErrorMessage = "公司邮箱长度不能超过 100 个字符")]
        [EmailAddress(ErrorMessage = "公司邮箱格式不正确")]
        public string? CompanyEmail { get; set; }

        /// <summary>
        /// 电话
        /// </summary>
        [StringLength(100, ErrorMessage = "电话长度不能超过 100 个字符")]
        public string? CompanyPhone { get; set; }

        /// <summary>
        /// 企业地址
        /// </summary>
        [StringLength(200, ErrorMessage = "企业地址长度不能超过 200 个字符")]
        public string? CompanyAddress { get; set; }
    }
}
